
// import oimo.common.Vec3;

import { Vec3 } from "../../common/Vec3";

/**
 * The result point is a pair of the closest points of collision geometries
 * detected by a collision detector. This holds relative closest points for
 * each collision geometry and the amount of the overlap.
 */

export class DetectorResultPoint {
	/**
	 * The first collision geometry's closest point.
	 */
	position1: Vec3;

	/**
	 * The second collision geometry's closest point.
	 */
	position2: Vec3;

	/**
	 * The amount of the overlap. This becomes negative if two geometries are
	 * separate.
	 */
	depth: number;

	/**
	 * The identification of the result point.
	 */
	id: number;


	constructor() {
		this.position1 = new Vec3();
		this.position2 = new Vec3();
		this.depth = 0;
		this.id = 0;
	}
}
